From 2413f0efee2dcb4cd4c9389f5a496d4b3f71335c Mon Sep 17 00:00:00 2001 From: MohamedBassem Date: Tue, 5 Mar 2024 19:38:34 +0000 Subject: fix: Show loading indicators in the bookmark preview page --- .../app/dashboard/preview/[bookmarkId]/page.tsx | 54 +--------------------- 1 file changed, 2 insertions(+), 52 deletions(-) (limited to 'packages/web/app/dashboard/preview/[bookmarkId]/page.tsx') diff --git a/packages/web/app/dashboard/preview/[bookmarkId]/page.tsx b/packages/web/app/dashboard/preview/[bookmarkId]/page.tsx index 030ad2df..47aeb891 100644 --- a/packages/web/app/dashboard/preview/[bookmarkId]/page.tsx +++ b/packages/web/app/dashboard/preview/[bookmarkId]/page.tsx @@ -1,8 +1,5 @@ -import { BackButton } from "@/components/ui/back-button"; import { api } from "@/server/api/client"; -import { ArrowLeftCircle, CalendarDays, ExternalLink } from "lucide-react"; -import Link from "next/link"; -import Markdown from "react-markdown"; +import BookmarkPreview from "./components/BookmarkPreview"; export default async function BookmarkPreviewPage({ params, @@ -13,52 +10,5 @@ export default async function BookmarkPreviewPage({ bookmarkId: params.bookmarkId, }); - const linkHeader = bookmark.content.type == "link" && ( -
-

{bookmark.content.title}

- - View Original - - -
- ); - - let content; - switch (bookmark.content.type) { - case "link": { - content = ( -
- ); - break; - } - case "text": { - content = {bookmark.content.text}; - break; - } - } - - return ( -
-
- - - -
- - {bookmark.createdAt.toLocaleString()} - -
-
-
- {linkHeader} -
- {content} -
-
- ); + return ; } -- cgit v1.3-1-g0d28